home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Cream of the Crop 25
/
Cream of the Crop 25.iso
/
os2
/
vac23.zip
/
adeptrexxmiscfuncs.doc
< prev
next >
Wrap
Text File
|
1997-02-20
|
80KB
|
2,592 lines
AdeptXBBS REXX INTERFACE
Copyright (c) 1993 - 1996 by AdeptSoft
portions Copyright (c) 1991-1994 M. Kimes
All Rights Reserved
AdeptSoft, AdeptXBBS, GateKeeper,
are trademarks of AdeptSoft.
"XBBS" Copyright (c) 1988 - 1994 by M. Kimes. The "XBBS" name is a
Trademark of M. Kimes.
ADEPT REXX INTERFACE
---------------------------------------------------------------------------
AdeptXBBS comes with two 'menu' systems, the standard text, ASCII
based menu system and a REXX subsystem. The REXX subsystem
included with the BBS software allows all basic menu functions with
some additional flexibility.
We also offer, still in development, a complete REXX API subsystem
that gives even the novice programmer control over the BBS
software.
With the AdeptXBBS REXX API Programming module you get access to all
available memory variables, all internal functions, and
unrestricted access to all running nodes at one time.
This is an extremely powerful module, giving control over the
entire BBS. For programmers wishing to write their own programs in a
simple language, yet maintain the speed and flexibility of AdeptXBBS
this is for you. We also have utilities that allow you to ship your
programs without making the source code available to the end user.
Adept contains a REXX interface to the BBS functions. This allows you
to create your own scripts to execute from Adept. By using REXX
functions alone you can completely customize Adept.
Three types of REXX commands can be automatically executed by Adept.
They are .cmd, .srx and .erx files. To be executed they need only
exist in the .\Menus directory. Below is a list of .cmd files that
Adept will automatically run if they exist in the .\Menus directory.
Main.Cmd or Main?.Cmd
---------------------
This REXX script is executed INSTEAD OF the default menu system.
AtEnd.Cmd or AtEnd?.Cmd
-----------------------
This REXX script is executed after the user logs off (or the default
script has ended) The BPS rate will be zero and the time left will be
five minutes. This script is executed before the user info is saved to
the user data base.
AtStart.Cmd or AtStart?.Cmd
---------------------------
This REXX script is executed at logon. The filename with the line
number is executed in place of 'AtStart.Cmd' if it exists.
Exception.Cmd
-------------
This REXX script is executed if a exception violation occurs. You can
use this script to notify the user of what just happened. And to help
assist us by asking the user what they where doing when the exception
happened.
ConvertXXX.Cmd
--------------
Where 'XXX' is a file extension of a type of file you wish to convert
to another format. For instance, if you want to convert ARC files to
ZIP,you would create a ConvertARC.CMD ConvertARC.Cmd would then
convert the file, if the file is converted it creates a file called
"xxxxx.NewName" where 'xxxxx' is the file name without the extension
This file contains 1 line, the line has the new filename of the file
after it was converted. Adept will use this filename when it puts
the file info into the file system.
ChatReq.Cmd or ChatReq?.Cmd
---------------------------
Where '?' is the line number.
Fax.Cmd or Fax?.Cmd
-------------------
Where '?' is the line number. Executed when modem returns a fax result
code.
Standard and Extended REXX Programs:
------------------------------------
.SRX stands for Standard REXX files. They are the same as .CMD files
in that they are not compiled in any way. .ERX files are REXX files
that have been preprocessed with the AdeptREXX Processor (Srx2Erx).
ERX files are typically 50% smaller and always faster then standard
REXX files (When run Cached).
We are asking that people who write rexx scripts for Adept that are
not preprocessed please use the extension .SRX. The preprocessor
will ONLY process files with the .SRX extension.
Srx2Erx.Exe FileNameWithoutExtention will yield a file with the same
name, but the .ERX extension. If you are a commercial developer is
recommended that you preprocess your rexx .SRX files before
distributing them. Also it recommended that you DO NOT preprocess
the following!
Atstart.Cmd - This MUST remain a .CMD file. So that others may modify
it and chain needed rexx scripts (preprocessed or not) from it.
The BBS software will only look for .ERX versions of files that we feel are
OK to preprocess. In fact if you are running a .SRX file (i.e. .cmd)
file in cached mode (as we default to) it is treated as a .ERX file
after we preprocess it internally. So it is honestly recommended that
you do not preprocess anything that you are NOT going to be
distributing.
Proper REXX Programming Syntax:
-------------------------------
ALL REXX functions in the software unless you are looking for a value
should be called with the CALL function NOT with the () method.
i.e.
Call AdeptChainRexx "RexxCmdFile.Cmd", line
NOT
AdeptChainRexx("RexxCmdFile.Cmd", line)
The call method is always preferred but sometimes the API set does not
call for it. Those functions must be set equal to some variable as they
return a value to the calling Script.
The second one will usually work correctly but not always. It is always
preferred to use the first method.
ADEPT REXX INTERFACE CALLS
---------------------------------------------------------------------------
Adept registers functions which can be called from the REXX
interpreter. These calls are used to interface a REXX script to
number as the first argument to the function. The REXX script should
store that line number because it must be passed back to the
AdeptREXX functions as the first parameter.
Remember to Start every REXX script with /* <text if any> */ then on
the next line (or the one after) Do the following ..
ARG Line
*OR*
ARG LineNumber
Remember, if you use "Line", then all your REXX Function must have the
first parameter as "Line". If you use "LineNumber" then all your REXX
functions must have the first parameter as "LineNumber". If you have
used ARG Line and in a function you have put "LineNumber" (where it's
supposed to be) then nothing will happen :), so you must remember to
always use the same argument that you started with.
** Example **
You used ARG Line so all your Functions (AdeptPrint, AdeptCall,
AdeptInput, etc..) will have to be passed like so:
Call AdeptPrint Line,"String"
and NOT
Call AdeptPrint LineNumber, "String"
It is the same if you have the two reversed. So really, where ever you
see "LineNumber" in this file, you replace it with the argument you
stated at the beginning of the REXX script.
Note:
Strings:
Strings in REXX are denoted by the double quote mark. Characters are
marked by singe quotes. "String" 'A'
Empty Parameters:
If the function you wish to use does not require all the parameters
filled in, do not simply terminate the function call when you have put
all the parameters in that you need. Continue to complete the function
definition with commas with no intervening spaces.
Example:
Call AdeptCall Linenumber,1,,'cmd.exe /c twar.bat'
Notice that the flags field is empty and that there are no
intervening spaces.
Debugging Scripts:
When your script has terminated abnormally you will notce an integer
value in the Recent Events Screen. To find out what the error was
record that integer value down and open an OS/2 window and type
help rex(ReturnNumber)
So if you have an error and the value in the Recent Events window is
(-6), Open up an OS/2 window and type help rex6
FUNCTION LISTING
---------------------------------------------------------------------------
AdeptGetVersion()
FUNCTION USAGE
Value = AdeptGetVersion()
ARGUMENTS
None
RETURNED VALUE
Returns the Current Adept Version
DESCRIPTION
Returns the Current Adept Version
NOTE
EXAMPLE
Call AdeptPrint line,"Running AdeptXBBS Version "||AdeptGetVersion()
RELATED FUNCTIONS
---------------------------------------------------------------------------
AdeptGetTempUser()
FUNCTION USAGE
Value = AdeptGetTempUser(UserName)
ARGUMENTS
UserName:
Users' Name
RETURNED VALUE
Returns a userid to be used by the TempUser family of functions.
DESCRIPTION
Gets a Temporary User record.
NOTE
EXAMPLE
userid = AdeptGetTempUser("Paul Meyer")
RELATED FUNCTIONS
AdeptGetTempUserVar()
AdeptPutTempUserVar()
AdeptFreeTempUser()
AdeptSaveTempUser()
---------------------------------------------------------------------------
AdeptGetTempUserVar()
FUNCTION USAGE
Call AdeptGetTempUserVar UserID, Variable
or
Value = AdeptGetTempUserVar(UserID, Variable)
ARGUMENTS
UserID:
Userid Created by AdeptGetTempUser.
Variable:
Number of variable to return. Where the value can be a number
between 1 and 62 (See AdeptGetVar() for the list of variables)
RETURNED VALUE
Returns the contents of the variable requested from userid.
DESCRIPTION
Gets a Variable from a Temporary User record.
NOTE
EXAMPLE
tempuserhandle = AdeptGetTempUserVar(userid,2)
RELATED FUNCTIONS
AdeptGetTempUser()
AdeptPutTempUserVar()
AdeptFreeTempUser()
AdeptSaveTempUser()
---------------------------------------------------------------------------
AdeptPutTempUserVar()
FUNCTION USAGE
Call AdeptGetTempUserVar UserID, Variable, Value
or
Value = AdeptGetTempUserVar(UserID, Variable, Value)
ARGUMENTS
UserID:
Userid Created by AdeptGetTempUser.
Variable:
Number of variable to place value. Where the variable can be a
number between 1 and 62 (See AdeptGetVar() for the list of variables)
Value:
New value to place in Variable.
RETURNED VALUE
DESCRIPTION
Places value in a Temporary User record.
NOTE
EXAMPLE
This example would change the user Joe Bloggs' handle to Sysop.
userid = AdeptGetTempUser("Joe Bloggs")
Call AdeptPutTempUserVar userid, 2, "Sysop"
Call AdeptSaveTempUser userid
Call AdeptFreeTempUser userid
RELATED FUNCTIONS
AdeptGetTempUser()
AdeptGetTempUserVar()
AdeptFreeTempUser()
AdeptSaveTempUser()
---------------------------------------------------------------------------
AdeptFreeTempUser()
FUNCTION USAGE
Call AdeptFreeTempUser UserID
or
Value = AdeptFreeTempUser(UserID)
ARGUMENTS
UserID:
Userid Created by AdeptGetTempUser.
RETURNED VALUE
DESCRIPTION
Frees the userid record.
NOTE
EXAMPLE
Call AdeptFreeTempUser userid
RELATED FUNCTIONS
AdeptGetTempUser()
AdeptGetTempUserVar()
AdeptPutTempUserVar()
AdeptSaveTempUser()
---------------------------------------------------------------------------
AdeptSaveTempUser()
FUNCTION USAGE
Call AdeptSaveTempUser UserID
or
Value = AdeptSaveTempUser(UserID)
ARGUMENTS
UserID:
Userid Created by AdeptGetTempUser.
RETURNED VALUE
DESCRIPTION
Saves any changes made to the userid record.
NOTE
EXAMPLE
Call AdeptSaveTempUser userid
RELATED FUNCTIONS
AdeptGetTempUser()
AdeptGetTempUserVar()
AdeptPutTempUserVar()
AdeptFreeTempUser()
---------------------------------------------------------------------------
AChatSendMsg()
FUNCTION USAGE
Call AChatSendMsg LineNumber, Flags, MsgTo, Text
ARGUMENTS
LineNumber:
Node Number passed to REXX routine from Adept as first parameter.
Flags:
To be deciphered :)
MsgTo:
Name to send message to.
Text:
Text to send.
RETURNED VALUE
DESCRIPTION
NOTE
This function is untested and due to the fact that other functions
similar to this do not exist anymore/are not completed, this function
may not exist in the future.
EXAMPLE
RELATED FUNCTIONS
---------------------------------------------------------------------------
Adept16BitCRC()
FUNCTION USAGE
Value = Adept16BitCRC(LineNumber, String)
ARGUMENTS
LineNumber:
Node Number passed to REXX routine from Adept as first parameter.
String:
String to CRC
RETURNED VALUE
Returns 16bit CRC'd version of String
DESCRIPTION
Returns the 16bit CRC version of the String passed.
NOTE
EXAMPLE
RELATED FUNCTIONS
Adept32BitCRC()
---------------------------------------------------------------------------
Adept32BitCRC()
FUNCTION USAGE
Value = Adept32BitCRC(LineNumber, String)
ARGUMENTS
LineNumber:
Node Number passed to REXX routine from Adept as first parameter.
String:
String to CRC
RETURNED VALUE
Returns 32bit CRC'd verision of String
DESCRIPTION
Returns the 32bit CRC version of the String passsed.
NOTE
Use to check users' password.
EXAMPLE
RELATED FUNCTIONS
Adept16BitCRC()
---------------------------------------------------------------------------
AdeptAddToXferList()
FUNCTION USAGE
Call AdeptAddToXferList LineNumber, File
ARGUMENTS
LineNumber:
Node Number passed to REXX routine from Adept as first parameter.
File:
Path/Filename of file to add to list.
RETURNED VALUE
DESCRIPTION
Adds File to the users tagged file list.
NOTE
EXAMPLE
Call AdeptAddToXFerList line,"/files/newfiles.txt"
RELATED FUNCTIONS
AdeptClearXFerList()
---------------------------------------------------------------------------
AdeptCall()
FUNCTION USAGE
Call AdeptCall LineNumber, Type, Flags, String1, ..., StringN
or
Value = AdeptCall(LineNumber, Type, Flags, String1, ..., StringN)
ARGUMENTS
LineNumber:
Node Number passed to REXX routine from Adept as first parameter.
Type:
1 Same as menu item 801. Spawn a separate session.
Strings are concatenated to form one string which is
used as the spawn string. Can be used for a door
program that accesses the com port in a more
traditional (and complicated) fashion.
You can run DOS doors here also.
Flags: 1 - Start session in background.
2 Same as menu item 802. Run OS/2 type door.
(same as menu item 800 but assumes a program which is
more friendly to having its I/O redirected thru pipes
to the com port.) Program must allow itself to be
killed.
Flags: Not Used.
3 Same as menu item 800. Run OS/2 type door. Program must
allow itself to be killed.
Flags: Not Used.
Flags:
Only Used for a Type 1 call.
1 Start session in background.
String1..N:
Strings are added together to form one string which is used to
spawn the session.
RETURNED VALUE
0 No Error
DESCRIPTION
Runs an external program. All sessions inherit Adepts environment.
NOTE
EXAMPLE
The following EXAMPLE would call the batch file twar.bat and run
TradeWars in the Foreground.
Call AdeptCall Linenumber,1,,'cmd.exe /c twar.bat'
RELATED FUNCTIONS
---------------------------------------------------------------------------
AdeptChainRexx()
FUNCTION USAGE
Call AdeptChainRexx "RexxScriptName", LineNumber
or
Value = AdeptChainRexx("RexxScriptName", LineNumber)
ARGUMENTS
RexxScriptName:
Name and path of file you want to run.
LineNumber:
Node Number passed to REXX routine from Adept as first parameter.
RETURNED VALUE
DESCRIPTION
Chains REXX files within REXX files. Runs the rexx script in cached
mode.
NOTE
EXAMPLE
RELATED FUNCTIONS
AdeptChainRexxNc()
---------------------------------------------------------------------------
AdeptChainRexxNc()
FUNCTION USAGE
Call AdeptChainRexxNc "RexxScriptName", LineNumber
ARGUMENTS
RexxScriptName:
Name and path of file you want to run.
LineNumber:
Node Number passed to REXX routine from Adept as first parameter.
RETURNED VALUE
DESCRIPTION
Chains REXX files within REXX files. Runs the rexx script in
cached mode.
NOTE
Once a script is cached by Adept into Memory it will remain there
until you shut down Adept. So if you modify a script, the changes
will not take effect until you shutdown Adept.
EXAMPLE
The following would chain the REXX file Pager.ERX from another REXX
script and not cache the script into memory.
Call AdeptChainRexxNc "D:\Adept\Batch\Pager.Erx",LineNumber
RELATED FUNCTIONS
AdeptChainRexx()
---------------------------------------------------------------------------
AdeptChangeGroup()
FUNCTION USAGE
Call AdeptChangeGroup LineNumber, GroupNum
or
Value = AdeptChangeGroup(LineNumber, GroupNum)
ARGUMENTS
LineNumber:
Node Number passed to REXX routine from Adept as first parameter.
GroupNum:
Number that corresponds to the group level that you want to
change the user to.
RETURNED VALUE
0 Users group was not upgraded or GroupNum not found.
1 Successful upgrade.
DESCRIPTION
This works just like upgrading a users group in the local user
editor. The user will take on the changes specified for the specific
group that they have joined/are in.
NOTE
EXAMPLE
The following EXAMPLE will change the current user to group level 10.
Call AdeptChangeGroup LineNumber, 10
RELATED FUNCTIONS
---------------------------------------------------------------------------
AdeptCheckCard()
FUNCTION USAGE
Call AdeptCheckCard(LineNumber, String)
ARGUMENTS
LineNumber:
Node Number passed to REXX routine from Adept as first parameter.
RETURNED VALUE
0 on error
>0 for no error
DESCRIPTION
NOTE
EXAMPLE
RELATED FUNCTIONS
---------------------------------------------------------------------------
AdeptCheckBit()
FUNCTION USAGE
Call AdeptCheckBit Linenumber, BitNumber, Numeric Long
or
Value = AdeptCheckBit(Linenumber, BitNumber, Numeric Long)
ARGUMENTS
LineNumber:
Node Number passed to REXX routine from Adept as first parameter.
BitNumber:
Which bit number to check.
Numeric Long:
A numeric long to be checked. ie - User Flags.
RETURNED VALUE
1 Bit is set
0 Bit is not set
DESCRIPTION
This can be used to test if a users bit is turned on for any of
the LONG bitmap'd flags.
NOTE
EXAMPLE
The following EXAMPLE will check to see if the current user has
bit number 10 turned on. If so, it will print "Flag 10 is on!"
If the bit is not set, it will not print anything.
UserFlag = AdeptGetVar(LineNumber, 42) /* 42 - User Flags */
IsOn = AdeptCheckBit(LineNumber, 10, UserFlag)
if IsOn = '1' then
Call AdeptPrint LineNumber, "Flag 10 is on!\r\n"
RELATED FUNCTIONS
AdeptSetBit()
AdeptUnSetBit()
---------------------------------------------------------------------------
AdeptClearXferList()
FUNCTION USAGE
Call AdeptClearXferList LineNumber
ARGUMENTS
LineNumber:
Node Number passed to REXX routine from Adept as first parameter.
RETURNED VALUE
DESCRIPTION
Empties users' Tagged file list
NOTE
EXAMPLE
Call AdeptClearXferList line
RELATED FUNCTIONS
AdeptAddToXFerList()
---------------------------------------------------------------------------
AdeptCls()
FUNCTION USAGE
Call AdeptCls LineNumber
or
Value = AdeptCls(LineNumber)
ARGUMENTS
LineNumber:
Node Number passed to REXX routine from Adept as first parameter.
RETURNED VALUE
DESCRIPTION
Clears local and remote screen.
NOTE
EXAMPLE
The following EXAMPLE will clear the screen
Call AdeptCls LineNumber
RELATED FUNCTIONS
---------------------------------------------------------------------------
AdeptConvert()
FUNCTION USAGE
Value = AdeptConvert(LineNumber, String)
ARGUMENTS
LineNumber:
Node Number passed to REXX routine from Adept as first parameter.
String:
String which contains META variables which need to be converted.
RETURNED VALUE
Converted string.
DESCRIPTION
Converts META variables passed in String.
NOTE
EXAMPLE
The following EXAMPLE will convert the Meta variable {F5 to dred.
{F5 is the Meta var for the color dark red. So where ever you use
dred it will put it in Dark Red since there are some Functions
that do not support Meta Codes (NOT just color, ALL Meta Codes)
dred=AdeptConvert(LineNumber,'{F5')
RELATED FUNCTIONS
---------------------------------------------------------------------------
AdeptCurPos()
FUNCTION USAGE
Call AdeptCurPos LineNumber, Row, Column
or
Value = AdeptCurPos(LineNumber, Row, Column)
ARGUMENTS
LineNumber:
Node Number passed to REXX routine from Adept as first parameter.
Row:
Screen row to move the cursor to.
Column:
Screen column to move the cursor to.
RETURNED VALUE
"row col" - returns the row value then the column value separated by
a space.
DESCRIPTION
Moves Cursor to row, column
NOTE
EXAMPLE
Call AdeptCurPos line,20,10
RELATED FUNCTIONS
---------------------------------------------------------------------------
AdeptDropGlobalVar()
FUNCTION USAGE
RetCode = AdeptDropGlobalVar('VarName')
ARGUMENTS
RETURNED VALUE
DESCRIPTION
AdeptDropGlobalVar will free the memory space occupied by VarName,
where VarName is a Global Variable made by AdeptSetGlobalVar.
NOTE
EXAMPLE
AdeptDropGlobalVar('VarName')
RELATED FUNCTIONS
AdeptGetGlobalVar()
AdeptSetGlobalVar()
---------------------------------------------------------------------------
AdeptFile()
FUNCTION USAGE
Call AdeptFile LineNumber, Type, StartAt, KeyName
ARGUMENTS
LineNumber:
Node Number passed to REXX routine from Adept as first parameter.
Type:
1 Returns name of current file area.
2 Returns number of current file area.
3 Find file area by number.
Returns file area number
4 Find file area by name.
Returns name of current file area.
5 Go to next file area
Returns name of current file area.
6 Go to previous file area
Returns name of current file area.
7 Returns download path of current file area.
8 Returns upload path of current file area.
StartAt:
Only required for Type 3.
Number of area to look for.
Keyname:
Only required for Type 4.
Name of area to look for.
RETURNED VALUE
Type:
1 Name of current file area.
2 Number of current file area.
3 File area number.
4 File area name.
5 Sets area to the Next file area and returns file area name.
6 Sets area to the Previous file area and returns file area name.
7 Download path of current file area.
8 Upload path of current area.
DESCRIPTION
File area manipulation
NOTE
EXAMPLE
Call AdeptFile LineNumber,4,,"AdeptSoft" /* This would find the File
area "AdeptSoft" as
listed in File_Areas */
Call AdeptFile LineNumber,5,,"" /* Goto next area */
Call AdeptFile LineNumber,6,,"" /* Goto previous area */
RELATED FUNCTIONS
AdeptMessage()
AdeptLibrary()
---------------------------------------------------------------------------
AdeptGetGlobalVar()
FUNCTION USAGE
RetCode = AdeptGetGlobalVar('VarName')
ARGUMENTS
VarName:
Name of global variable.
RETURNED VALUE
Returns value of the global variable.
DESCRIPTION
AdeptGetGlobalVar will pull a variable's value out of memory.
NOTE
EXAMPLE
RetCode = AdeptGetGlobalVar('STATUS')
RELATED FUNCTIONS
AdeptSetGlobalVar()
AdeptDropGlobalVar()
---------------------------------------------------------------------------
AdeptGetVar() and
AdeptPutVar()
FUNCTION USAGE
Value = AdeptGetVar(LineNumber, varnumber)
or
Value = AdeptPutVar(LineNumber, varnumber, Data)
ARGUMENTS
LineNumber:
Node Number passed to REXX routine from Adept as first parameter.
varnumber:
Variable number from the list below.
Data:
Data that you want to replace in varnumber.
RETURNED VALUE
DESCRIPTION
This function duplicates some of the functions already in the
AdeptREXX language. This returns almost every single variable
Adept uses in the BBS software. This will give a REXX programmer
total control over all of the BBS's users and mailers memory
variables.
There will also be some new variables added that will be blank.
These variables will be usable in real time across nodes by
multiple REXX programs running at the same time. The
possibilities of such a setup are limitless.
NOTE
The following are the variable numbers:
User Info:
1 - Users Name
2 - Users Handle
3 - Users Address
4 - Users Address1
5 - Users Address2
6 - Users City
7 - Users State
8 - Users Zipcode
9 - Users Home Phone
10 - Users Data Phone
11 - Users Fax Phone
12 - Users Business Phone
13 - Users Interests
14 - Sysop Comment about User
15 - Users Bank Time
16 - Users Computer Type (Number)
17 - Users User ID
18 - Users Point ID
19 - Users BirthYear
20 - Users BirthMonth
21 - Users BirthDay
22 - Users Gender (Represented by 1 letter)
23 - Users NetMail Credit
25 - The Group the User belongs to
27 - Time Used Today
28 - Time Per Day
29 - Time Per Call
30 - Number of calls the user has made
31 - Upload Number
32 - Download Number
33 - Uploads in K
34 - Downloads in K
35 - Upload K today
36 - Download K today
37 - Upload K per day (Max Allowed)
38 - Download K per day (Max Allowed)
39 - Number of posts (Total)
40 - Security Level #1
41 - Security Level #2
42 - Flags represented as a 32-bit long
43 - Flags2 Represented as a 32-bit long
44 - User Attributes represented as a 32-bit long
45 - User Attributes #2 represented as a 32-bit long
46 - Users Screen Length
47 - Users Screen width
48 - Last Message Area number user was in
49 - Last File Area Number user was in
50 - Last Protocol Chosen (Returns the letter for the protocol)
51 - Last Archiver Chosen Returns Archive Letter
53 - Percentage of Upload/Download ratio to consider the user a
leech
54 - Maximum Bank time allowed for this user
55 - Password Represented as a 32-bit long (32-bit CRC)
56 - Password reversed represented as a 32-bit long (32-bit
CRC)
57 - Max Messages to pack into a mail packet.
58 - Users Age
59 - User Bad Password Attempts
60 - MailStatus (I forget how we use this at the moment)
61 - Number of lines shown to the remote user since last reset
(clear screen or new screen shown, etc). This is
calculated by the display subsystem and should always be
correct.
This variable takes everything from ANSI and Avatar cursor
movement into account, to number of actual lines
displayed.
62 - Did the user pick non-stop display after the last more
prompt or non-stop display choice.
BBS Info:
100 - Number of Calls to the BBS
101 - Last User ID Assigned by the BBS
102 - Last Point ID Assigned by the BBS
103 - Minimum Age Required to Log on
104 - Maximum Age Allows on the BBS
105 - Amount of NetMail Credit the user has
106 - Expire Users after x amount of days
107 - Expire Users after x amount of minutes
108 - Default User Time Per Day
109 - Default User Security Level #1
110 - Default User Security Level #2
111 - BBS User Default Flags #1 returned as a 32-bit long
112 - BBS User Default Flags #2 returned as a 32-bit long
113 - Default Upload K per day max
114 - Maximum download k per day
115 - BBS User Default Attribs returned as a 32-bit long
116 - BBS User Default Attribs #2 returned as 32-bit long
117 - The default group the user belongs to. The user will
inherit the default settings for this group. 0 for none.
118 - Maximum Users to allow in the user file
119 - Default Origin Line for EchoMail Areas
120 - Maximum Password Attempts Allowed
125 - Default Cost to send a NetMail message
126 - Line number the BBS is on in the quote file
127 - Default Maximum Time Per Call
128 - I don't remember I will have to check this one (ulmulti)
129 - Odds of getting a quote when called
130 - Mailer Incoming Password Protected Mail Path
131 - Mailer OkFile for Password Protected Nodes
132 - Mailer Incoming Public Mail Path
133 - Mailer OkFile for Public Mail
134 - Mailer Unlisted Node Mail Path
135 - Mailer OkFile for Unlisted Nodes
136 - Number of times a user can page the sysop
137 - The BBS's Name
138 - BBS UAttribs 32-bit long
139 - BBS UAttribs #2 32-bit long
140 - Sysops Name
141 - Is The Sysop In (0 or 1)
142 - Default Max Messages in Packet
143 - City/State info for BBS & .QWK Packet
144 - .QWK BBS ID
145 - BBS .QWK Phone Number
146 - Default Max Bank Time
Modem/Mailer Info:
200 - Modem Handle
201 - Node Number
202 - Port Name (COM1, \PIPE\ADEPT1, etc)
203 - Modem Init String
204 - Default Dialing Prefix
205 - Default Dialing Suffix
206 - Optional Dialing Prefix #1
207 - Optional Dialing Suffix #1
208 - Optional Dialing Prefix #2
209 - Optional Dialing Suffix #2
210 - Optional Dialing Prefix #3
211 - Optional Dialing Suffix #3
212 - Optional Dialing Prefix #4
213 - Optional Dialing Suffix #4
214 - Optional Dialing Prefix #5
215 - Optional Dialing Suffix #5
216 - Optional Dialing Prefix #6
217 - Optional Dialing Suffix #6
218 - Optional Dialing Prefix #7
219 - Optional Dialing Suffix #7
220 - Optional Dialing Prefix #8
221 - Optional Dialing Suffix #8
222 - Modem Answer String
223 - Obsolete
224 - Obsolete
225 - Mail Only Event Text
226 - Text if User is too slow
228 - Baud Rate to Init Modem at
229 - Minimum Baud rate Allowed on BBS
230 - Minimum Incoming Baud Rate for Mail
231 - Minimum Baud Rate to Call Out for Mail
232 - Maximum Baud Rate for Outbound Mail
233 - Current Baud Rate of Modem
234 - Minimum Cost of Mail for This Event (Dialout)
235 - Maximum Cost of Mail for This Event (Dialout)
236 - Maximum Mail in K to send in a mail session
237 - Maximum Time Limit for a mail session
239 - Maximum Bad Mail Calls before no more are made
240 - Maximum Times to call a node to send mail
241 - If Port Locked (0 / 1)
242 - Allow Human Callers or Users on the BBS? (0/1)
243 - Allow File Requests (0/1)
244 - Accept File Request (0/1)
245 - Dialing Out OK?
246 - OK To Answer the Phone?
248 - Force FTS-0001 Mail Sessions (0/1)
249 - Receive Mail From Unlisted Nodes? (0/1)
250 - Send Mail to Unlisted Nodes? (0/1)
251 - Was the last incoming call to the BBS or Mail
(1 for BBS, 0 for mailer)
252 - Sealink Overdrive Off (0/1) 1 = off
253 - Sealink Mail On/Off (1 = on)
254 - 1k Sealink On/Off (1 = off)
255 - Allow DietINFA (1 = on (TBBS & XBBS use dietINFA))
256 - In Chat with Sysop (0/1)
257 - Debug Transfers (0/1) Extra Log Info
258 - Allow Hydra Mail Transfers (0/1) (Currently Disabled)
259 - Allow ZedZip for Mail Transfers (0/1)
260 - Allow ZedZap for Mail Transfer (0/1)
261 - Turn the mailer off? (0/1) 1 = off
262 - Key to represent Yes (Y) for USA
263 - Key to represent No (N) for USA
264 - Key to represent Stop (S) for USA
264 - Key to represent Pause (P) for USA
264 - Key to represent Quit (Q) for USA
268 - Maximum # of resyncs to abort transfers
269 - Maximum # of transfer errors to abort on
270 - Last Users on this lines name
271 - Last Mailer to call this node
272 - Last Long Entry Written
276 - Check Carrier Detect (0/1) 1 = on
277 - Video Display Handle
278 - Number of ring to wait for answer on this node
EXAMPLE
The following would come out like "Welcome to AdeptSoft! You are welcomed
by Julie Strietelmeier". (Except AdeptSoft would be your BBS name and
Julie Strietelmeier would be your name.
BBSname=AdeptGetVar(LineNumber,137)
SYSOPname=AdeptGetVar(LineNumber,140)
AdeptPrint(line,"\r\nWelcome to " BBSname "! You are welcomed by "
SYSOPname)
RELATED FUNCTIONS
---------------------------------------------------------------------------
AdeptHitReturn()
FUNCTION USAGE
Call AdeptHitReturn LineNumber
ARGUMENTS
LineNumber:
Node Number passed to REXX routine from Adept as first parameter.
RETURNED VALUE
DESCRIPTION
AdeptHitReturn will wait for the user to press enter. This will
use the Press Enter to continue in the English.Text or other
language file.
NOTE
EXAMPLE
The following would prompt the user to press Enter (return) to continue.
Call AdeptHitReturn LineNumber
RELATED FUNCTIONS
AdeptMore()
---------------------------------------------------------------------------
AdeptInKey()
FUNCTION USAGE
Call AdeptInKey LineNumber
or
Value = AdeptInKey(LineNumber)
ARGUMENTS
LineNumber:
Node Number passed to REXX routine from Adept as first parameter.
RETURNED VALUE
0 No Keys waiting
If the function does not return 0, then it will return the ASCII
code for the incoming key sequence.
DESCRIPTION
AdeptInKey will return the ASCII code for a incoming key sequence.
AdeptInKey will not wait for a key, it will return 0 if there are
no keys waiting. If you use this in a loop, please offset the
amount of CPU time a loop uses with a AdeptSleep command.
NOTE
EXAMPLE
ReturnCode = AdeptInKey(LineNumber)
RELATED FUNCTIONS
AdeptTimedInKey()
AdeptWaitKey()
---------------------------------------------------------------------------
AdeptInput()
FUNCTION USAGE
Value = AdeptInput(LineNumber, MinLen, MaxLen, Type, Flags,
Prompt, Help, HelpFile, Default)
ARGUMENTS
LineNumber:
Node number passed to REXX routine from Adept as first parameter.
MinLen:
Minimum length of input string.
MaxLen:
Maximum length of input string.
Type:
/* Types for AdeptInput */
STRT_ALPHA /* Letters Only */
STRT_NUMERIC /* Numbers Only */
STRT_ALPHANUMERIC /* Letters and Numbers Only */
STRT_HEX /* Read as Hexadecimal */
STRT_FILENAME /* Read as Filename */
STRT_FILESPEC /* Read as File Spec (ie *.*) */
STRT_ALL /* Read All Keys */
STRT_ANY /* Read Any ? Same as above? */
STRT_YN /* Yes or No (Y/N) */
STRT_MULTFILES
STRT_MULTSPECS
STRT_YNQ
STRT_YNQS
STRT_JUSTFILE
STRT_MULTJUST
STRT_TELEPHONE
STRT_YNNUM
Flags:
/* Flags for AdeptInput */
STRF_UCASE /* Uppercased Input */
STRF_LCASE /* Lowercased Input */
STRF_REQUIRED /* Input is Required */
STRF_NOECHO /* Don't echo typing to screen */
STRF_ENCRYPT /* Encrypt? */
STRF_HOT /* Hotkey Input Don't wait for CRLF */
STRF_EDIT /* Means INS DEL etc work? */
STRF_PRETTY /* I think this is First letter Uppercased */
STRF_MUSTHOT /* Required+Hot? */
STRF_NEAT /* Neat? Same as pretty? */
STRF_NOHELP /* Don't look up help file */
STRF_NOQUE /* ??? */
STRF_NOQUEONE /* ??? */
STRF_CHATCLNT /* ??? */
STRF_NOTIMECHECK /* Don't check time remaining */
Prompt:
Prompt to display when asking for input.
Help:
Name of subject to look for in HelpFile when user asks for help.
HelpFile:
Contains help on subjects pertaining to this input prompt.
Default:
Default keystroke.
RETURNED VALUE
Returns the string read from the user.
DESCRIPTION
Get a string from the user.
NOTE
Make sure you call AdeptInitREXX before using any of the flags
or types.
EXAMPLE
The following would ask the User for his or her name with a MinLen
of 1 Character and a MaxLen of 50 Characters, with a prompt of "What
is your Name". When this is printed, it will print to the local
and remote screen "Your Name is Jean-Ray" (Jean-Ray being the
name entered).
answer=AdeptInput(LineNumber,1,50,,,'What Is your Name: ',,,)
Call AdeptPrint LineNumber,'\r\n Your name is' answer
RELATED FUNCTIONS
AdeptInKey()
AdeptTimedInKey()
---------------------------------------------------------------------------
AdeptKillRexxThread()
FUNCTION USAGE
AdeptKillRexxThread(TID)
ARGUMENTS
TID:
Thread ID
RETURNED VALUE
0 No error
0> Error
DESCRIPTION
Terminates the rexx thread with the ID "TID".
NOTE
Terminating a running thread can return a REXX Error 40 (Program
Interrupted). You can suppress this error message by using the
Signal on Halt keyword.
If you want to share variables between a REXX thread and its parent,
use the AdeptSetGlobalVar() and AdeptGetGlobalVar() functions.
EXAMPLE
This example will start a rexx script called ftp_progress.cmd in a
thread, meaning it will run at the same time as the calling script.
It will then kill the thread when the calling script no longer needs
it.
Tid = AdeptStartRexxThread("ftp_progress.cmd",line,file)
.
.
.
AdeptKillRexxThread(Tid)
RELATED FUNCTIONS
AdeptStartRexxThread()
---------------------------------------------------------------------------
AdeptLibrary()
FUNCTION USAGE
Call AdeptLibraryLineNumber, Type, StartAt, KeyName
ARGUMENTS
LineNumber:
Node number passed to REXX routine from Adept as first parameter.
Type:
1 Returns name of current library area.
2 Returns number of current library area.
3 Find library area by number
Returns library area number
4 Find library area by name
Returns name of current library area.
5 Go to next library area
Returns name of current library area.
6 Go to previous library area
Returns name of current library area.
7 Returns path of current library area.
StartAt:
Ony required for Type 3.
Number of area to look for.
Keyname:
Only required for Type 4.
Name of area to look for.
RETURNED VALUE
Type:
1 Name of current library area.
2 Number of current library area.
3 Library area number.
4 Library area name.
5 Sets area to the Next library area and returns the area name.
6 Sets area to the Previous library area and returns the area
name.
7 Path of current library area.
DESCRIPTION
Library area manipulation.
NOTE
The Adept Library Functions are not yet finished.
EXAMPLE
RELATED FUNCTIONS
AdeptFile()
AdeptMessage()
---------------------------------------------------------------------------
AdeptLocation()
FUNCTION USAGE
Call AdeptLocation LineNumber, "User Location on the BBS"
or
Value = AdeptLocation(LineNumber, "User Location on the BBS")
or
Location = AdeptLocation(LineNumber)
ARGUMENTS
RETURNED VALUE
Users' Location
DESCRIPTION
Will display where the User is on the BBS (Sysop defined). If the
location is omitted, the function will return the users' current
location.
NOTE
Remember, Once the script ends, the location will go back to what
it was before the function was executed. This function however is
great for Doors and Chat Mode with the Sysop if you use a Main.Cmd
or a .Cmd file for your Door Menu. It can let other users know what
Door the other node(s) are in if any.
EXAMPLE
This would display the user on that particular line in a Door of
Barren Realms Elite.
Call AdeptLocation LineNumber,"In Door - Barren Realms Elite"
RELATED FUNCTIONS
AdeptSayGen()
---------------------------------------------------------------------------
AdeptLog()
FUNCTION USAGE
Call AdeptLog LineNumber, Flags, String1, ..., StringN
or
Value = AdeptLog(LineNumber, Flags, String1, ..., StringN)
ARGUMENTS
LineNumber:
Node number passed to REXX routine from Adept as first parameter.
Flags:
1 Output to log only
2 Output to listbox only
3 Output to log and listbox
String1..N:
Strings are added together to form one string which is used to
create the string to log.
RETURNED VALUE
DESCRIPTION
Log an action to the logfile and/or listbox.
NOTE
EXAMPLE
Call AdeptLog LineNumber,2, "User entered AdeptVote"
Call AdeptLog LineNumber,3, "MainMenu Started"
RELATED FUNCTIONS
---------------------------------------------------------------------------
AdeptMenu()
FUNCTION USAGE
Call AdeptMenu LineNumber, Flags, MenuName
or
Value = AdeptMenu(LineNumber, Flags, MenuName)
ARGUMENTS
LineNumber:
Node number passed to REXX routine from Adept as first parameter.
Flags:
1 Return after user chooses a command from the menu.
2 Return after executing all commands contained in menu.
MenuName:
File name of the menu to use.
RETURNED VALUE
DESCRIPTION
Executes a menu contained in the file MenuName.
NOTE
EXAMPLE
Call AdeptMenu LineNumber,2, "AskPhoneNumbers.Menu"
Call AdeptMenu LineNumber,1, "Message.Menu"
RELATED FUNCTIONS
---------------------------------------------------------------------------
AdeptMenuType()
FUNCTION USAGE
Call AdeptMenuType LineNumber, MenuType, MenuData
or
Value = AdeptMenuType(LineNumber, MenuType, MenuData)
ARGUMENTS
LineNumber:
Node number passed to REXX routine from Adept as first parameter.
MenuType:
MenuType to execute. See ADPXBBS.DOC for list of menutypes.
MenuData:
Optional data to be sent to MenuType.
RETURNED VALUE
DESCRIPTION
This function let's you use one of Adept's menu types in a rexx
script. See the ADPXBBS.DOC file for more info on menu types.
When using menutype 10, put quotes around the file name.
NOTE
Menu types below menu type 10 are not allowed for this function.
Only 10 and above are legal.
EXAMPLE
This command allows you to execute a menu options 10 - 998. Just
pass the standard menudata.
Call AdeptMenuType LineNumber,42,,,0 /* This would display The
Users online at the current
time. */
Call AdeptMenuType LineNumber,900,"" /* Your Mailbox */
Call AdeptMenuType LineNumber,15,"" /* New mail read */
Call AdeptMenuType LineNumber,16,,"" /* Quickscan messages */
Call AdeptMenuType LineNumber,78,"" /* List files in area */
Call AdeptMenuType LineNumber,76,"" /* KeyWord Search */
Call AdeptMenuType LineNumber,74,"" /* New files */
Call AdeptMenuType LineNumber,85,"" /* Download */
Call AdeptMenuType LineNumber,90,"" /* Upload a file */
Call AdeptMenuType LineNumber,146,"" /* Select Default Protocol */
RELATED FUNCTIONS
---------------------------------------------------------------------------
AdeptMessage()
FUNCTION USAGE
Call AdeptMessage LineNumber, Type, StartAt, KeyName
ARGUMENTS
LineNumber:
Node number passed to REXX routine from Adept as first parameter.
Type:
1 Returns name of current message area.
2 Returns number of current message area.
3 Find message area by number
Returns message area number
4 Find message area (name of area to find in KeyName)
Returns name of current message area.
5 Go to next message area
Returns name of current message area.
6 Go to previous message area
Returns name of current message area.
7 Returns number of messages in current message area.
8 Lists available message areas to user.
9 Sets the first message area, in the message area list,
that user is currently 'looking at'
(the user is not necessarily in the area)
The name of the area is returned if one is available,
otherwise '-1' is returned.
This function type is useful when listing message areas.
This function type should be called before using type 10.
10 Sets the next message area, in the message area list,
that user is currently 'looking at'. It is the next area
based on the current area the user is 'looking at'.
(the user is not necessarily in the area)
The name of the area is returned if one is available,
otherwise '-1' is returned.
This function type is useful when listing message areas.
You must call AdeptMessage() with the type 9 before using
this function, or results will be undefined!
11 Sets the previous message area, in the message area list,
that user is currently 'looking at'. It is the previous
area based on the current area the user is 'looking at'.
(the user is not necessarily in the area)
The name of the area is returned if one is available,
otherwise '-1' is returned.
This function type is useful when listing message areas.
You must call AdeptMessage() with the type 9 before using
this function, or results will be undefined!
12 Sets the next message area, in the message area list,
that user is currently 'looking at'. It is the next area
based on the current area the user is in.
The name of the area is returned if one is available,
otherwise '-1' is returned.
13 Sets the previous message area, in the message area list,
that user is currently 'looking at'. It is the previous
area based on the current area the user is in.
The name of the area is returned if one is available,
otherwise '-1' is returned.
StartAt:
Only required for Type 3.
Number of area to look for.
Keyname:
Only required for Type 4.
Name of area to look for.
RETURNED VALUE
Depends on the type used.
DESCRIPTION
Message area manipulation.
NOTE
Types 5 and 6 have pecularities. Do not use the Call method on them.
EXAMPLE
Would find message area Number 1 as listed in the
Adept\System\Message_Areas file.
Call AdeptMessage LineNumber,3,'1',
AdeptMessage(LineNumber,5,,"") /* Goto next area */
AdeptMessage(LineNumber,6,,"") /* Goto previous area */
RELATED FUNCTIONS
AdeptFile()
AdeptLibrary()
---------------------------------------------------------------------------
AdeptMore()
FUNCTION USAGE
Call AdeptMore LineNumber
ARGUMENTS
LineNumber:
Node number passed to REXX routine from Adept as first parameter.
RETURNED VALUE
DESCRIPTION
AdeptMore will execute a standard more prompt. This will use the
More prompt in the English.Text or other language file. This will
also use the International Y/N/Q/A info.
EXAMPLE
Call AdeptMore LineNumber
RELATED FUNCTIONS
AdeptHitReturn()
---------------------------------------------------------------------------
AdeptPause()
FUNCTION USAGE
Call AdeptPause LineNumber
or
Value = AdeptPause(LineNumber)
ARGUMENTS
LineNumber:
Node number passed to REXX routine from Adept as first parameter.
RETURN VALUE
DESCRIPTION
AdeptPause will wait for any key. This does not display any text.
NOTE
EXAMPLE
Will wait for any key to be pressed on current node.
Call AdeptPause LineNumber
RELATED FUNCTIONS
AdeptWaitKey()
---------------------------------------------------------------------------
AdeptPlayMM()
FUNCTION USAGE
Call AdeptPlayMM LineNumber, Filename
ARGUMENTS
LineNumber:
Node Number passed to REXX routine from Adept as first parameter.
Filename:
Name of WAV file to play.
RETURNED VALUE
DESCRIPTION
Plays a WAV sound file.
NOTE
EXAMPLE
Call AdeptPlayMM line,"/sounds/paging.wav"
RELATED FUNCTIONS
---------------------------------------------------------------------------
AdeptPostTextMessage()
FUNCTION USAGE
Call AdeptPostTextMessage LineNumber, AreaNum, To, From, Subject,
File, IsPrivate
ARGUMENTS
LineNumber:
Node number passed to REXX routine from Adept as first parameter.
AreaNum:
Message area number to post the message in.
To:
Name of the person to whom the message should go to.
From:
Name of the person that the message is from.
Subject:
The subject for the message.
File:
Name of the text file to use as the message.
IsPrivate:
If omitted, message is public, else private.
RETURNED VALUE
There's no return code
DESCRIPTION
Post a message using a text file as the message.
IsPrivate may be ommited. If so, the msg is assumed public. All other
parameters are manadtory. Node maybe 0 if the rexx program isn't
running in a particular node (ie. a global script).
NOTE
EXAMPLE
RELATED FUNCTIONS
AdeptWrite()
---------------------------------------------------------------------------
AdeptPrint()
FUNCTION USAGE
Call AdeptPrint LineNumber, String1, ..., StringN
ARGUMENTS
LineNumber:
Node number passed to REXX routine from Adept as first parameter.
String1..N:
Strings are printed in the order that they were passed.
RETURNED VALUE
DESCRIPTION
Prints a string to the local and remote screen. The string may
contain Adept META variables. You may pass more than one or more
strings to this function.
NOTE
EXAMPLE
This Would print "Hello! Welcome to The BBS" to the User online.
Call AdeptPrint LineNumber,"Hello! Welcome to The BBS"
RELATED FUNCTIONS
AdeptPrintL()
---------------------------------------------------------------------------
AdeptPrintL()
FUNCTION USAGE
Call AdeptPrintL LineNumber, String1, ..., StringN
ARGUMENTS
LineNumber:
Node number passed to REXX routine from Adept as first parameter.
String1..N:
Strings are printed in the order that they were passed.
RETURNED VALUE
DESCRIPTION
AdeptPrintL works exactly like AdeptPrint except it prints to the
LOCAL screen only.
NOTE
EXAMPLE
RELATED FUNCTIONS
AdeptPrint()
---------------------------------------------------------------------------
AdeptPutKey()
FUNCTION USAGE
Call AdeptPutKey LineNumber, Char
or
Value = AdeptPutKey(LineNumber, Char)
ARGUMENTS
LineNumber:
Node number passed to REXX routine from Adept as first parameter.
Char:
Character to put into the keyboard input stream
RETURNED VALUE
DESCRIPTION
AdeptPutKey will place a character into keyboard input stream.
Char can be a character i.e. 'A' or a ASCII character code.
NOTE
EXAMPLE
Will put the Character 'A' in the Keyboard's input stream.
Call AdeptPutKey LineNumber,'A'
RELATED FUNCTIONS
---------------------------------------------------------------------------
AdeptRead()
FUNCTION USAGE
Call AdeptRead LineNumber, Type, Flags, StartAt
or
Value = AdeptRead(LineNumber, Type, Flags, StartAt)
ARGUMENTS
LineNumber:
Node number passed to REXX routine from Adept as first parameter.
Type:
1 Read messages in current area.
2 Globally read messages.
Flags:
(for Type 1)
1 Show only messages to user
2 Show only messages from user
8 Don't clear top of screen
16 Read Reverse (default is forward)
(for Type 2)
1 Stop at all areas
8 Don't clear top of screen
StartAt:
Number of message at which Adept should start reading.
StartAt is not used with global message reading.
RETURNED VALUE
(for Type 1)
Direction user is reading in. 1 = User is reading forward,
-1 = user is reading backwards.
(for Type 2)
Returns 0
DESCRIPTION
Read messages.
You should do a carrier check after this function to make sure
the user is online.
EXAMPLE
Call AdeptRead LineNumber,2,,4 /* This would start the user
currently online reading the
messages globally starting from
Message Area #4 (as defined in
Adept\System\Message_Areas
file). */
Call AdeptRead line,1,,1 /* This will start reading messages
in the current area */
RELATED FUNCTIONS
AdeptWrite()
---------------------------------------------------------------------------
AdeptRecv()
FUNCTION USAGE
Call AdeptRecv LineNumber, Flags, Path, Area, File1, ..., FileN
or
Value = AdeptRecv(LineNumber, Flags, Path, Area, File1, ..., FileN)
ARGUMENTS
LineNumber:
Node number passed to REXX routine from Adept as first parameter.
Flags:
1 No time verification
4 Silence
8 Never be silent
16 Don't ask for DESCRIPTION
64 Don't credit upload (does not return files size)
128 Accept as private file.
Path:
Path to put files in.
Area:
Name of area to put files in.
File1..N:
Names of files to be received.
RETURNED VALUE
String containing number of bytes downloaded, a space and the
number of files downloaded.
DESCRIPTION
Upload files
NOTE
This function will change in the future.
EXAMPLE
This will send the File Adept97b.Zip from the AdeptSoft area and
the directory of D:\ADEPT
Call AdeptRecv line,128,'D:\ADEPT','AdeptSoft','Adept97b.Zip'
RELATED FUNCTIONS
AdeptSend()
---------------------------------------------------------------------------
AdeptRequestsLogoff()
FUNCTION USAGE
Value = AdeptRequestsLogoff(LineNumber)
ARGUMENTS
LineNumber:
Node number passed to REXX routine from Adept as first parameter.
RETURNED VALUE
1 if Adept wants user logged off
0 if User can stay
DESCRIPTION
Will check if Adept wants the user to be logged off. ie - if user
is out of time or has timed out
NOTE
EXAMPLE
if(AdeptRequestsLogoff(line)==1)then
exit
RELATED FUNCTIONS
---------------------------------------------------------------------------
AdeptSayGen()
FUNCTION USAGE
Call AdeptSayGen LineNumber, String
or
Value = AdeptSayGen(LineNumber, String)
ARGUMENTS
LineNumber:
Node number passed to REXX routine from Adept as first parameter.
String:
Status String.
RETURNED VALUE
0 No error
0> Error
DESCRIPTION
Sets the "user location" for the given node in the Adept line status
window.
NOTE
EXAMPLE
The following example sets the message in the Line Status Window to
reflect that the user is playing LORD.
Call AdeptSayGen line, "Legend Of The Red Dragon"
RELATED FUNCTIONS
AdeptLocation()
---------------------------------------------------------------------------
AdeptSend()
FUNCTION USAGE
Call AdeptSend LineNumber, Flags, Path, File1, ..., FileN
Call AdeptSend LineNumber,,,''@file''
or
Value = AdeptSend(LineNumber, Flags, Path, File1, ..., FileN)
Value = AdeptSend(LineNumber,,,''@file'')
ARGUMENTS
LineNumber:
Node number passed to REXX routine from Adept as first parameter.
Flags:
1 No time verification
2 No leech checking
4 Silence
8 Never be silent
16 Don't check all download paths
64 Don't return files length (free file/bytes)
Path:
Path to files. If blank, use current file area path.
File1..N:
Names of files to be sent.
NOTE: Currently the files are sent one at a time.
@File:
Text file with the filenames and paths (one per line) of
the files to send.
RETURNED VALUE
String containing number of bytes downloaded, a space and the
number of files downloaded.
DESCRIPTION
Download Files.
NOTE
EXAMPLE
Will send the File that is in the file called list.
Call AdeptSend LineNumber,,,'@c:\list')
RELATED FUNCTIONS
AdeptRecv()
AdeptAddToXFerList()
---------------------------------------------------------------------------
AdeptSetBit()
FUNCTION USAGE
Call AdeptSetBit LineNumber, Bit Number, Numeric Long
or
Value = AdeptSetBit(LineNumber, Bit Number, Numeric Long)
ARGUMENTS
LineNumber:
Node number passed to REXX routine from Adept as first parameter.
BitNumber:
Which bit number to set.
Numeric Long:
A numeric long to be manipulated. ie - User Flags.
RETURNED VALUE
DESCRIPTION
Will set Bit Number to ON.
NOTE
The changes are not saved until you put the changes back into
active memory with the AdeptPutVar option.
EXAMPLE
SetBit = AdeptGetVar(LineNumber, 42)
Call AdeptSetBit LineNumber, 30, SetBit
RELATED FUNCTIONS
AdeptCheckBit()
AdeptUnSetBit()
---------------------------------------------------------------------------
AdeptSetGlobalVar()
FUNCTION USAGE
RetCode = AdeptSetGlobalVar('VarName', Value)
ARGUMENTS
VarName:
Name of variable enclosed in quotes.
Value:
Value to assign to VarName.
RETURNED VALUE
DESCRIPTION
AdeptSetGlobalVar will set a global variable named VarName in
memory with a value of VarValue.
NOTE
EXAMPLE
Value = 6
RetCode = AdeptSetGlobalVar('VarName', Value)
RELATED FUNCTIONS
AdeptGetGlobalVar()
AdeptDropGlobalVar()
---------------------------------------------------------------------------
AdeptSetTimer()
FUNCTION USAGE
Call AdeptSetTimer LineNumber, Timer
or
Value = AdeptSetTimer(LineNumber, Timer)
ARGUMENTS
LineNumber:
Node number passed to REXX routine from Adept as First Parameter.
Timer:
Time In Milliseconds
RETURNED VALUE
DESCRIPTION
Starts a timer.
NOTE
EXAMPLE
Call AdeptSetTimer LineNumber,10000 /* 10 seconds */
RELATED FUNCTIONS
AdeptTimerUp()
---------------------------------------------------------------------------
AdeptShow()
FUNCTION USAGE
Call AdeptShow LineNumber, Type, Flags, StartAt, KeyName
ARGUMENTS
LineNumber:
Node number passed to REXX routine from Adept as first parameter.
Type:
1 Show a text file (StartAt=filename, KeyName=keys to abort
on)
2 Page-read text file (Keyname=filename)
3 Show new text files (Keyname=directory to look in)
4 Show any text file (Keyname=directory to look in)
Flags:
<undefined> (for now)
StartAt:
(see type 1)
KeyName:
Keys on which to abort showing of the text file. (see type 1)
-or-
Name of file or directory to look for. (see types 2-4)
RETURNED VALUE
DESCRIPTION
Display text files.
NOTE
EXAMPLE
The following will display the Bullet.Ans file in the Adept\Text
directory and if the User presses the letter 'Q' it will abort
viewing of the file.
Call AdeptShow LineNumber,1,,'C:\Adept\Text\Bullet.Ans,Q
RELATED FUNCTIONS
---------------------------------------------------------------------------
AdeptSleep()
FUNCTION USAGE
Call AdeptSleep LineNumber, time_to_sleep_in_milliseconds
or
Value = AdeptSleep(LineNumber, time_to_sleep_in_milliseconds)
ARGUMENTS
LineNumber:
Node number passed to REXX routine from Adept as first parameter.
time_to_sleep_in_milliseconds:
1000 milliseconds = 1 second.
The smallest timeslice OS/2 can sleep is 32ms.
RETURNED VALUE
DESCRIPTION
AdeptSleep will cause the current node to sleep for x amount of
milliseconds. This is very helpful in making your REXX scripts
CPU friendly. When you use this command it will release the
current time slice to the next node or program waiting in line.
A decent sleep amount is AdeptSleep(65), 65 milliseconds, 1000
NOTE
EXAMPLE
Call AdeptSleep LineNumber,1000 /* 1 Second */
Call AdeptSleep LineNumber,10000 /* 10 Seconds */
Call AdeptSleep LineNumber,60000 /* 1 Minute */
Call AdeptSleep LineNumber,600000 /* 10 Minutes */
RELATED FUNCTIONS
---------------------------------------------------------------------------
AdeptStartRexxThread()
FUNCTION USAGE
RetCode = AdeptStartRexxThread(FileName, [var1 var2 var3 var4])
ARGUMENTS
FileName:
Name of AdeptREXX program to execute as a background thread.
Var1 ...:
Variable to pass to the rexx program, you can pass as many variables
you want. They are not shared once they are passed.
RETURNED VALUE
Thread ID >0 if thread started
DESCRIPTION
This will cause the program Thread.Cmd to be run in the
background with the rexx programming calling it as the parent.
When the parent ends, all children and grandchildren are
killed with it.
NOTE
EXAMPLE
rc = AdeptStartRexxThread('Thread.Cmd', line)
RELATED FUNCTIONS
AdeptKillRexxThread()
AdeptStartRexxThreadNC()
---------------------------------------------------------------------------
AdeptStartRexxThreadNC()
FUNCTION USAGE
RetCode = AdeptStartRexxThread(FileName, [var1 var2 var3 var4])
ARGUMENTS
FileName:
Name of AdeptREXX program to execute as a background thread.
Var1 ...:
Variable to pass to the rexx program, you can pass as many variables
you want. They are not shared once they are passed.
RETURNED VALUE
Thread ID >0 if thread started
DESCRIPTION
This will cause the program Thread.Cmd to be run in the
background with the rexx programming calling it as the parent.
When the parent ends, all children and grandchildren are
killed with it. Starts Thread in non-cached mode.
NOTE
EXAMPLE
rc = AdeptStartRexxThread('Thread.Cmd', line)
RELATED FUNCTIONS
AdeptKillRexxThread()
AdeptStartRexxThread()
---------------------------------------------------------------------------
AdeptTimedInKey()
FUNCTION USAGE
Call AdeptTimedInKey LineNumber, Timeout
or
Value = AdeptTimedInKey(LineNumber, Timeout)
ARGUMENTS
LineNumber:
Node number passed to REXX routine from Adept as first parameter.
Timeout:
Timeout period. In Milliseconds.
RETURNED VALUE
Value for key inputed.
If no key is pressed with in the timeout value a -1 or 0 for timeout.
If the Carrier is lost a value of -2 is returned.
If the SysOp presses F3 on the local BBS Window -3 is returned.
If the SysOp presses F4 on the local BBS Window -4 is returned.
DESCRIPTION
Returns the value for the key inputed, watched the port for a
period of time in milliseconds.
NOTE
EXAMPLE
KeyIn=AdeptTimedInKey(LineNumber,5000) /* 5 seconds */
RELATED FUNCTIONS
AdeptInput()
AdeptInKey()
AdeptWaitKey()
---------------------------------------------------------------------------
AdeptTimeLeft()
FUNCTION USAGE
Call AdeptTimeLeft LineNumber [, SecsLeftInSession]
or
Value = AdeptTimeLeft(LineNumber [, SecsLeftInSession])
ARGUMENTS
LineNumber:
Node number passed to REXX routine from Adept as first parameter.
SecsLeftInSession:
Optional. Set seconds left in current session.
RETURNED VALUE
Time left in session in seconds.
DESCRIPTION
Optionally sets time left in current session. Always returns time
left in current session.
NOTE
EXAMPLE
This will give the user online 1 minute left in his/her session.
Call AdeptTimeLeft LineNumber, 60000
RELATED FUNCTIONS
---------------------------------------------------------------------------
AdeptTimerUp()
FUNCTION USAGE
Call AdeptTimerUp LineNumber, Timer
or
Value = AdeptTimerUp(LineNumber, Timer)
ARGUMENTS
LineNumber:
Node number passed to REXX routine from Adept as first parameter.
Timer:
The return value of the AdeptSetTimer function.
RETURNED VALUE
0 Time is up
1 Time is not up
DESCRIPTION
Checks to see if the timer is up.
NOTE
EXAMPLE
The following example sets the timer to 10 seconds and then checks to
see if the time is up.
** EXAMPLE with the TWO PREVIOUS rexx Functions **
Timer=AdeptSetTimer(LineNumber,10000) /* 10 Seconds */
MyRet=AdeptTimerUp(LineNumber,timer)
RELATED FUNCTIONS
AdeptSetTimer()
---------------------------------------------------------------------------
AdeptUnsetBit()
FUNCTION USAGE
Call AdeptUnsetBit LineNumber, Bit Number, Numeric Long
or
Value = AdeptUnsetBit(LineNumber, Bit Number, Numeric Long)
ARGUMENTS
LineNumber:
Node number passed to REXX routine from Adept as first parameter.
Bit Number:
Which bit number to set.
Numeric Long:
A numeric long to be manipulated. ie - User Flags.
RETURNED VALUE
DESCRIPTION
Will set Bit Number to OFF.
NOTE
The changes are not saved until you put the changes back into active
memory with the AdeptPutVar option.
EXAMPLE
The following example will turn bit number 30 OFF.
Call AdeptUnsetBit LineNumber, 30, SetBit
RELATED FUNCTIONS
AdeptSetBit()
AdeptCheckBit()
---------------------------------------------------------------------------
AdeptWaitKey()
FUNCTION USAGE
Call AdeptWaitKey LineNumber
or
Value = AdeptWaitKey(LineNumber)
ARGUMENTS
LineNumber:
Node number passed to REXX routine from Adept as first parameter.
RETURNED VALUE
ASCII code for the key pressed.
DESCRIPTION
AdeptWaitKey will return the ASCII code for a incoming key
sequence. Unlike AdeptInKey, AdeptWaitKey will actually wait for
a key sequence. If the user times out, it will log the user off.
NOTE
EXAMPLE
ReturnCode = AdeptInKey(LineNumber)
RELATED FUNCTIONS
AdeptInKey()
AdeptTimedInKey()
---------------------------------------------------------------------------
AdeptWrite()
FUNCTION USAGE
Call AdeptWrite LineNumber, Type, Flags, Filename
or
Value = AdeptWrite(LineNumber, Type, Flags, Filename)
ARGUMENTS
LineNumber:
Node number passed to REXX routine from Adept as first parameter.
Type:
1 Write a message (Filename is unused)
2 edit a file using editor (Flags are unused)
Flags:
1 Force message to force-to-name of current message area.
2 Force private
4 Force public
8 Use MSGTMP.LineNumber file
Filename:
Name of text file to edit.
RETURNED VALUE
DESCRIPTION
Write a message.
NOTE
EXAMPLE
This would prompt a user to write a public message in the current
area.
Call AdeptWrite LineNumber, 1, 4,""
RELATED FUNCTIONS
AdeptPostTextMessage()
AdeptRead()
---------------------------------------------------------------------------
Print()
FUNCTION USAGE
RetCode = Print(LineNumber, Arg1, ....)
ARGUMENTS
LineNumber:
Node number passed to REXX routine from Adept as first parameter.
Arg1 ...:
1st argument to be displayed
RETURNED VALUE
0 No errors.
-1 REXX killed by BBS or Carrier lost
DESCRIPTION
Displays the argument(s) on the given line.
NOTE
Does not convert Meta's
EXAMPLE
RELATED FUNCTIONS
AdeptPrint()
AdeptPrintL()
---------------------------------------------------------------------------
Printf()
FUNCTION USAGE
Printf(Arg)
ARGUMENTS
Arg:
Argument to be displayed
RETURNED VALUE
0 No errors.
-1 REXX killed by BBS or Carrier lost
DESCRIPTION
Sends the argument to pmprintf. Useful ONLY to developers.
and even then only of limited value.
NOTE
It is better to use a combination of AdeptLog() and AdeptPrintL()
functions for debugging rather than using this.
EXAMPLE
RELATED FUNCTIONS
---------------------------------------------------------------------------
________________________________________________
_ _ CTRL AND OTHER KEYS AND THEIR RETURN CODES _
________________________________________________
CTRL_A = 1 CTRL_B = 2 CTRL_C = 3 CTRL_D = 4
CTRL_E = 5 CTRL_F = 6 CTRL_G = 7 CTRL_H = 8
CTRL_I = 9 CTRL_J = 10 CTRL_K = 11 CTRL_L = 12
CTRL_N = 14 CTRL_O = 15 CTRL_P = 16 CTRL_Q = 17
CTRL_R = 18 CTRL_S = 19 CTRL_T = 20 CTRL_U = 21
CTRL_V = 22 CTRL_W = 23 CTRL_X = 24 CTRL_Y = 25
CTRL_Z = 26
HOME = 71+1024 UP = 72+1024 PGUP = 73+1024 BS = 24
FWD = 77+1024 END = 79+1024 DN = 80+1024 PGDN = 1+1024
INS = 82+1024 DEL = 83+1024 LEFT = 75+1024 RIGHT = 77+1024